package nix.struts.param;

import nix.struts.param.domain.User;

import com.opensymphony.xwork2.ActionSupport;
import com.opensymphony.xwork2.ModelDriven;

public class Demo3Action extends ActionSupport implements ModelDriven<User> {
	// 使用对象成员变量接收参数（模型驱动）
	private User user = new User();

	@Override
	public String execute() throws Exception {

		System.out.println(user);
		return SUCCESS;
	}
	// 实现接口方法
	@Override
	public User getModel() {
		return user;
	}
}